import os

for exchange, fmt in [("Upbit", "%s-KRW"), ("Bithumb", "%s-KRW"), ("OkexFutures", "%s-USD.QUARTER"),
                      ("Okex", "%s-USDT"), ("Binance", "%s-USDT"), ("Huobi", "%s-USDT")]:
  if exchange.endswith("Futures"):
    exchange = exchange.replace("Futures", "")
    market_type = "Futures"
  else:
    market_type = "Spot"
  for coin in ["BTC", "XRP", "EOS", "ETH"]:
    coin_str = fmt % coin
    cmd = """./pyrunner coin/strategy/mm/tool/book_depth.py \
      --trading_date=20180920-20180924 --exchange=%s --market_type=%s \
      --symbol=%s --time_range=0-1 &> book_depth/%s_%s.txt""" % (
        exchange, market_type, coin_str, coin_str, exchange)
    print(cmd)
    os.system(cmd)
